package com.financing.platform.dao.impl;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Repository;

import com.financing.platform.dao.IFpRelevanceDao;
import com.financing.platform.dto.FpRelevanceDTO;
import com.financing.platform.util.SqlName;

@Repository("fpRelevanceDaoImpl")
public class FpRelevanceDaoImpl extends BaseDaoImpl implements IFpRelevanceDao {

	@Override
	public int addFpRelevance(FpRelevanceDTO fpRelevanceDTO)
			throws SQLException {
		 this.sqlMapClient.insert(SqlName.insertFpRelevance,fpRelevanceDTO);
		 return 0;
	}

	@Override
	public List<Map<String, String>> queryFpRelevance(
			FpRelevanceDTO fpRelevanceDTO) throws SQLException {
		return this.sqlMapClient.queryForList(SqlName.queryFpRelevance,fpRelevanceDTO);
	}

	@Override
	public int deleteFpRelevance(FpRelevanceDTO fpRelevanceDTO)
			throws SQLException {
		return this.sqlMapClient.update(SqlName.deleteFpRelevance,fpRelevanceDTO);
	}


}
